package com.hbnu.system.mapper;

import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.baomidou.mybatisplus.core.metadata.IPage;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.hbnu.system.model.entity.Tranproject_registration;
import com.hbnu.system.model.entity.User;
import com.hbnu.system.model.query.TranProjectExportQuery;
import com.hbnu.system.model.query.TranProjectPageQuery;
import com.hbnu.system.model.vo.ExportTranProjectVO;
import org.apache.ibatis.annotations.Param;

import java.util.List;

/**
 * <p>
 *  Mapper 接口
 * </p>
 *
 * @author ${author}
 * @since 2023-05-16
 */
public interface Tranproject_registrationMapper extends BaseMapper<Tranproject_registration> {
    // 校级审核员查询：指定参数名为page、tranProjectPageQuery、user
    IPage<Tranproject_registration> schoolGetRelateTranprojectQuery(
            @Param("page") Page<Tranproject_registration> page,
            @Param("tranProjectPageQuery") TranProjectPageQuery query,
            @Param("user") User user
    );


    // 用户查询：指定参数名为page、tranProjectPageQuery、user
    IPage<Tranproject_registration> userGetRelateTranprojectQuery(
            @Param("page") Page<Tranproject_registration> page,
            @Param("tranProjectPageQuery") TranProjectPageQuery query,
            @Param("user") User user
    );

    IPage<Tranproject_registration> schoolExportRelateTranprojectQuery(
            @Param("page") Page<Tranproject_registration> page,
            @Param("tranProjectPageQuery") TranProjectPageQuery query,
            @Param("user") User user
    );

    IPage<Tranproject_registration> userExportRelateTranprojectQuery(
            @Param("page") Page<Tranproject_registration> page,
            @Param("tranProjectPageQuery") TranProjectPageQuery query,
            @Param("user") User user
    );

    // 院级审核员查询
    IPage<Tranproject_registration> collegeGetRelateTranprojectQuery(
            @Param("page") Page<Tranproject_registration> page,
            @Param("tranProjectPageQuery") TranProjectPageQuery query,
            @Param("user") User user
    );

    // 院级审核员导出查询
    IPage<Tranproject_registration> collegeExportRelateTranprojectQuery(
            @Param("page") Page<Tranproject_registration> page,
            @Param("tranProjectPageQuery") TranProjectPageQuery query,
            @Param("user") User user
    );


    // 校级管理员导出横向项目
    List<ExportTranProjectVO> schoolExportTranProject(
            @Param("tranProjectExportQuery") TranProjectExportQuery query,
            @Param("user") User user
    );

    // 院级管理员导出横向项目
    List<ExportTranProjectVO> collegeExportTranProject(
            @Param("tranProjectExportQuery") TranProjectExportQuery query,
            @Param("user") User user
    );

    // 用户导出横向项目
    List<ExportTranProjectVO> userExportTranProject(
            @Param("tranProjectExportQuery") TranProjectExportQuery query,
            @Param("user") User user
    );

}